package com.tjsinfo.tjsoa.addresslist.action;

import java.util.List;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

import com.tjsinfo.tjsoa.addresslist.bo.IAddressListAndFilePendingBo;
import com.tjsinfo.tjsoa.common.SessionUser;


public class PenddingListAction extends Action{
	private IAddressListAndFilePendingBo addressListAndFilePendingBo;
	public void setAddressListAndFilePendingBo(
			IAddressListAndFilePendingBo addressListAndFilePendingBo) {
		this.addressListAndFilePendingBo = addressListAndFilePendingBo;
	}
	public ActionForward execute(ActionMapping mapping, ActionForm form,
			HttpServletRequest request, HttpServletResponse response) {
		
		Integer userid = SessionUser.getUser(request).getUser_id();
		List list = addressListAndFilePendingBo.findByUserIdAndTyle(userid, "通讯录");
		
		request.setAttribute("list", list);
		
		return mapping.findForward("ok");
	}
}
